<?php

class User_model extends CI_Model
{
	private $table = 'photo';
	
	public function authGranted($username, $password)
	{
		$this->db->where('user_username', $username);
		$this->db->where('user_password', $password);
		$this->db->where('user_status', 1);
		$query = $this->db->get('users');
		$result = $query->result_array();
		
		if ($result) {
			return TRUE;
		} else {
			return FALSE;
		}
	}
}